<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>第一题</title>
</head>

<body>
    <script>
        function gerarr() {
            let arr = ['张三', '李四', '王五', '孙六']
            let temp = arr[0]
            arr[0] = arr[3]
            arr[3] = temp
            temp = arr[1]
            arr[1] = arr[2]
            arr[2] = temp
            return arr
        }
        let jieguo = gerarr()
        console.log(jieguo)
    </script>
</body>

</html>